<script>
  function hideBanner() {
    const banner = document.getElementById("banner");
    if (banner) {
      banner.style.display = "none";
    }
    window.localStorage.setItem("hideBannerDate", Date.now().toString());
  }
  const hideBannerDate = parseInt(
    window.localStorage.getItem("hideBannerDate") || "0",
    10
  );
  if (
    !hideBannerDate ||
    Date.now() - hideBannerDate > 14 * 24 * 60 * 60 * 1000
  ) {
    const emojis = ["🎄", "🎅", "🎁", "🎉", "🦌", "🤶", "🌟", "🔔", "🧦"];
    const randomEmoji = document.getElementById("randomEmoji");
    if (randomEmoji) {
      randomEmoji.innerHTML = emojis[Math.floor(Math.random() * emojis.length)];
    }
    const banner = document.getElementById("banner");
    if (banner) {
      banner.style.display = "flex";
    }
  }
</script>
